package com.zhanghu.backendZray.service;

import com.zhanghu.backendZray.pojo.dto.MenuDTO;
import com.zhanghu.backendZray.pojo.entity.Menu;
import com.baomidou.mybatisplus.extension.service.IService;
import com.zhanghu.backendZray.pojo.request.menu.MenuRequest;
import com.zhanghu.backendZray.pojo.vo.MenuVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author zhangdong
 * @since 2024-07-20
 */
public interface MenuService extends IService<Menu> {

    List<MenuDTO> getMenusByUserId(@Param("userId") Integer userId);

    void add(MenuRequest menuRequest);

    void update(MenuRequest menuRequest);

    List<MenuVo> listAllTree();
    List<MenuVo> listAll();

    List<Integer> listAllMenuIdBYChildIdList(List<Integer> menuIdList);
}
